function single1(T,Npath,Ndt)
%function mctest(T,Npath,Ndt)
tic
myfun=@(s) 1+s-s;
paths=zeros(Npath,51);
dt=T/Ndt;
for ii=2:51
    curtime=0.01*(ii-2)+(1:100)*dt;
    cursigma=myfun(curtime);
    paths(:,ii)=paths(:,ii-1)+(randn(Npath,100)*cursigma')*sqrt(dt);    
end

    mcvar=sum(paths.^2,1)/Npath;
    toc
    plot((0:50)*0.5/50,mcvar)

